import { createConfigStore, createReducerManager } from "@/utils/store";
import user from "./user";

const middlewares = [require('redux-logger').createLogger()];
const globalReducer = {user};

export function configureStore(initialState: Record<string, any> = {}) {
  const reducerManager = createReducerManager(globalReducer);
  return createConfigStore(reducerManager, middlewares)(initialState);
}
